<template>
    <div class="not-found">
        <h1>401</h1>
        <p>抱歉，您暂无权限访问当前页面。</p>
        <dzs-button type="primary" @click="goToHome">返回首页</dzs-button>
        <br>
        <el-link type="primary" link @click="relogin">重新登录</el-link>
    </div>
</template>

<script setup lang="ts">
import { useRouter } from 'vue-router';

const router = useRouter();

const goToHome = () => {
    router.push('/');
};

const relogin = () => {
    window.location.href = "/login.html";
};
</script>

<style scoped>
.not-found {
    text-align: center;
    margin-top: 50px;
}

h1 {
    font-size: 10rem;
    color: #333;
}

p {
    font-size: 1.2rem;
    color: #666;
}

.dzs-button {
    margin-top: 20px;
}
</style>